﻿using Core;
using DataAccess;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace KhoaLuan.Account
{
    public partial class MyFileUC : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            tbUsers user = Session.GetCurrentUser();
            if (user != null)
            {
                txtId.Value = ConvertType.ToString(user.UserID);
                txtHoTen.Value = ConvertType.ToString(user.FullName);
                txtTendangnhap.Value = ConvertType.ToString(user.UserName);
                txtEmail.Value = ConvertType.ToString(user.Email);
                txtDiaChi.Value = ConvertType.ToString(user.Address);
                txtDiDong.Value = ConvertType.ToString(user.Mobile);
                txtSoDienThoai.Value = ConvertType.ToString(user.Phone);
            }
            else
            {
                Response.Redirect("~/Account/Login.aspx");
            }
        }
    }
}